package com.ibeeking.found.file.rest.service.office.entities;

import com.ibeeking.found.common.entity.CurrentUser;
import lombok.Getter;
import lombok.Setter;

import java.util.List;

@Getter
@Setter
public class UserEntity extends AbstractEntity {
    private String name;

    private String email;

    private Boolean favorite;

//    @ManyToOne
    private String group;

//    @OneToOne
    private PermissionEntity permissions;

//    @Column(columnDefinition = "CLOB")
//    @ElementCollection
//    @CollectionTable(name = "user_descriptions")
    private List<String> descriptions;

    public UserEntity(){}

    public UserEntity(CurrentUser userBean) {
        this.id = String.valueOf(userBean.getId());
        this.name = userBean.getName();
        this.group = "";

    }
}
